﻿using System.Collections.Generic;
using Yun.Interface;
using Yun.Response;

namespace Yun.Trade.Request
{
    /// <summary>
    /// 重新提交退款单申请，修改后，状态会自动转为下一阶段
    /// yun.trade.refund.resubmit
    /// </summary>
    public class ResubmitRefundRequest: ITopRequest<IntResultResponse>
    {
        /// <summary>
        /// 退款单编号
        /// </summary>
        public int OrderRefundId { get; set; }

        /// <summary>
        /// 备注留言
        /// </summary>
        public string Remark { get; set; }

        /// <summary>
        /// 凭证照片,多个用英文逗号隔开
        /// </summary>
        public string Images { get; set; }

        /// <summary>
        /// 退款件数
        /// </summary>
        public int? RefundQuantity { get; set; }


        /// <summary>
        /// 理由
        /// </summary>
        public string Reason { get; set; }

        /// <summary>
        /// 余额退款的金额
        /// </summary>
        public double Money { get; set; }


        public string GetApiName()
        {
            return "yun.trade.refund.resubmit";
        }

        public IDictionary<string, string> GetParameters()
        {
            var parameters = new YunDictionary
            {
                {"orderrefundid", OrderRefundId},
                {"reason", Reason},
                {"remark", Remark},
                {"money", Money},
                {"images",Images },
                {"refundquantity",RefundQuantity }
            };
            return parameters;
        }

        public void Validate()
        {
        }
    }
}
